package com.smartcampusbackend.mapper;

import com.smartcampusbackend.model.UserReadStatus;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import java.util.List;

@Mapper
public interface UserReadStatusMapper {
    int insertReadStatus(UserReadStatus readStatus);
    int updateReadStatus(UserReadStatus readStatus);
    UserReadStatus selectReadStatus(@Param("userId") Integer userId, @Param("announcementId") Integer announcementId);
    List<UserReadStatus> selectReadStatusByUser(@Param("userId") Integer userId, @Param("type") String type);
    int markAsRead(@Param("userId") Integer userId, @Param("announcementId") Integer announcementId);
    int batchInsertReadStatus(@Param("userId") Integer userId, @Param("announcementIds") List<Integer> announcementIds);
    int deleteReadStatusByAnnouncementId(@Param("announcementId") Integer announcementId);
} 